package it.antonio.ilpizze.db.index.hash.memory;

import it.antonio.ilpizze.db.index.hash.Element;
import it.antonio.ilpizze.db.index.hash.ElementList;

public class MemoryEntryList<K, V> implements ElementList<K, V> {
	
	private Element<K,V>[] elements;
	
	@SuppressWarnings("unchecked")
	public MemoryEntryList(int degree) {
		this.elements = new Element[degree];
	}

	@Override
	public Element<K, V> first(int index) {
		return elements[index];
	}

	@Override
	public void addFirst(int index, Element<K, V> first) {
		elements[index] = first;
	}

}
